# Contributor: dai9ah <dai9ah@protonmail.com>
# Maintainer: Celeste <cielesti@protonmail.com>
maintainer="Celeste <cielesti@protonmail.com>"
pkgname=bfs
pkgver=4.0.4
pkgrel=0
pkgdesc="Breadth-first variant of the UNIX find command"
url="https://github.com/tavianator/bfs"
arch="all"
license="0BSD"
makedepends="
	acl-dev
	attr-dev
	libcap-dev
	liburing-dev
	linux-headers
	oniguruma-dev
	"
checkdepends="bash acl coreutils"
subpackages="
	$pkgname-doc
	$pkgname-bash-completion
	$pkgname-zsh-completion
	$pkgname-fish-completion
	"
source="$pkgname-$pkgver.tar.gz::https://github.com/tavianator/bfs/archive/$pkgver.tar.gz"

build() {
	./configure \
		--enable-release \
		--with-libacl \
		--with-libcap \
		--with-liburing \
		--with-oniguruma
	make
}

check() {
	TEST_FLAGS="--verbose" make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
b372e68fc13624cd410edb64a0429fbb1dac2d01417c78821570b3b1d0e4f6d239d93acffcb5c077f84409edb013c9fec0b2bed50646ed52d62df90d6b1893fb  bfs-4.0.4.tar.gz
"
